<template>
  <!-- 制作一个组件 传给父组件 -->
  <div>
    <h2>作用域插槽子组件</h2>
    <div>姓名{{ first + last }}</div>
    <div>
      <slot :info="info" />
    </div>
  </div>
</template>
<script>
export default {
  name: 'Demo',
  props: {
    first: {
      type: String
    },
    last: {
      type: String
    }
  },
  computed: {
    info () {
      return {
        fn: this.first,
        la: this.last
      }
    }
  }
}
</script>
